package com.tangyuan.model.activity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * @Description: user_activity
 * @Author: jeecg-boot
 * @Date: 2024-03-20
 * @Version: V1.0
 */
@Data
@TableName("user_activity")
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "user_activity对象", description = "user_activity")
public class UserActivity implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(type = IdType.AUTO)
    @ApiModelProperty(value = "id")
    private Long id;
    /**
     * 用户id
     */
    @ApiModelProperty(value = "用户id")
    private Long userId;
    /**
     * 类型 0-活动 1-投票
     */
    @ApiModelProperty(value = "类型 0-活动 1-投票")
    private Integer type;
    /**
     * 海报url
     */
    @ApiModelProperty(value = "海报url")
    private String posterUrl;
    /**
     * 活动主题
     */
    @ApiModelProperty(value = "活动主题")
    private String subject;
    /**
     * 开始时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "开始时间")
    @NotNull(message = "请选择活动开始时间")
    private Date startTime;
    /**
     * 结束时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "结束时间")
    @NotNull(message = "请选择活动结束时间")
    private Date endTime;
    /**
     * 活动费用
     */
    @ApiModelProperty(value = "活动费用")
    private BigDecimal fee;
    /**
     * 活动形式 0-线上活动 1-线下活动
     */
    @ApiModelProperty(value = "活动形式 0-线上活动 1-线下活动")
    private Integer activityForm;
    /**
     * activityFormDescribe
     */
    @ApiModelProperty(value = "activityFormDescribe")
    private String activityFormDescribe;
    /**
     * 活动描述
     */
    @ApiModelProperty(value = "活动描述")
    private String activityDescribe;
    /**
     * 活动地址
     */
    @ApiModelProperty(value = "活动地址")
    private String activityAddress;
    /**
     * 出席人数
     */
    @ApiModelProperty(value = "出席人数")
    private Integer attendance;
    /**
     * 报名项设置
     */
    @ApiModelProperty(value = "报名项设置")
    private String signUp;
    /**
     * 售后电话
     */
    @ApiModelProperty(value = "售后电话")
    private String phone;
    /**
     * 审核状态 0-审核中 1-审核通过 2-审核未通过
     */
    @ApiModelProperty(value = "审核状态 0-审核中 1-审核通过 2-审核未通过")
    private Integer examine;
    /**
     * 活动状态 0-正常 1-取消 2-完成
     */
    @ApiModelProperty(value = "活动状态 0-正常 1-取消 2-完成")
    private Integer status;
    /**
     * 浏览量
     */
    @ApiModelProperty(value = "浏览量")
    private Integer readNum;
    /**
     * 投票数量
     */
    @ApiModelProperty(value = "投票数量")
    private Integer pollNum;
    /**
     * 新增时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "新增时间")
    private Date createTime;
    /**
     * 修改时间
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "修改时间")
    private Date updateTime;
    /**
     * 删除标识
     */
    @ApiModelProperty(value = "删除标识")
    @TableLogic
    private Integer isDeleted;

    @TableField(exist = false)
    private List<Long> honouredGuestIds;
    @TableField(exist = false)
    private List<Long> ticketTypeIds;
    @TableField(exist = false)
    private String name;
    // 用户头像 2024/5/28 上午 9:24 By 少帅
    @TableField(exist = false)
    private String headImage;
    @TableField(exist = false)
    private List<EnrollRecord> enrollRecords;
    @TableField(exist = false)
    private List<Enroll> enrolls;
    @TableField(exist = false)
    private List<PollRecord> pollRecords;

    @ApiModelProperty(value = "报名活动状态")
    private Integer isParticipate;

}
